package com.djbx.points.coupon;

import com.alibaba.cloud.seata.feign.SeataFeignClientAutoConfiguration;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.ComponentScans;

/**
 * @author Administrator
 * @date 2021/11/15 13:55
 */
@EnableDiscoveryClient
@RefreshScope
@EnableFeignClients(basePackages = "com.djbx.points.*.api.client")
@ComponentScans({
        //引入依赖模块配置
        @ComponentScan(basePackages = {"com.djbx.points.**.config"}),
        //引入服务降级
        @ComponentScan(basePackages = {"com.djbx.points.*.api.client"})
})
//分布式事务自定义，如果不依赖分布式事务，不需要排除
@SpringBootApplication(exclude = {SeataFeignClientAutoConfiguration.class})
public class PointsCouponApplication {
    public static void main(String[] args) {
        SpringApplication.run(PointsCouponApplication.class, args);
    }
}
